<?php

use Illuminate\Support\Facades\Route;
use Modules\Base\Http\Controllers\MaterialController;
use Modules\Base\Http\Controllers\BoxController;
use Modules\Base\Http\Controllers\BoxTurnoverController;
use Modules\Base\Http\Controllers\OrgController;

Route::prefix('base')->group(function(){

    //物料档案
	Route::apiResource('material', MaterialController::class);
	//物料档案修改
	Route::post('modifyMaterial', [MaterialController::class,'modifyMaterial']);

	//箱号
	Route::apiResource('box', BoxController::class);
    Route::put('box/enable/{id}', [BoxController::class, 'enable']);
    //箱号操作记录
    Route::get('box/log/{lotnum}', [BoxController::class, 'log']);
    Route::get('box/exist/{lotnum}', [BoxController::class, 'existLotnum']);

    //周转箱
	Route::apiResource('box/turnover', BoxTurnoverController::class);
    //领料箱号绑定
    Route::get('box/change/scan/{lotnum}',[BoxTurnoverController::class,'changeLotnum']);
    Route::post('box/change/scan',[BoxTurnoverController::class,'changeSubmit']);
});



